/*
 **********************************************************
 *
 * Program		:	slist.h
 *
 * written by	:	BAYRAMOV Matin
 *
 * description	:	a library with some functions to use simple
 * 					lists in C
 *
 * date			:	April 21, 2013
 *
 ***********************************************************
 */

#include <stdio.h>
#include <stdlib.h>

#include "macros.h"

#ifndef SLIST_H_
#define SLIST_H_

typedef struct sElement {
	int value;
	struct sElement *next;
} sElement;

typedef sElement *List;

// Print a simple list
int printSlist(List);

// Get size of a simple list
int getSizeSlist(List);

// Free memory of a simple list
int freeSlist(List);

// Add an element to the beginning of a simple list
List addBeginSlistElement(List, int);

// Add an element to the end of a simple list
List addEndSlistElement(List, int);

// Remove an element from a simple list
int removeSlistElement(List, int);

// Clone a simple list
int cloneSlist(List, List*);


#endif /* SLIST_H_ */
